<script>
import { defineComponent } from 'vue'
import { ref } from 'vue'

export default {
  setup() {
    const num = ref(0)
    // onMounted(() => {
    //   console.log('组件渲染了')
    // })
    return {
      num
    }
  },
  mounted(){
    
  }
}
</script>
<template>
  <div>
    <button @click="num++">数量{{num}}</button>
  </div>
</template>
